<table align="center" cellspacing="0" cellpadding="5">
  <tr>
    <td width="10%" align="left"><?php echo Kohana::lang('customer_lang.lbl_username')?>: <font color="#FF0000">*</font></td>
    <td><input type="text" name="txt_username" id="txt_username" size="50" value="<?php echo isset($mr['customers_username'])?$mr['customers_username']:''?>"/></td>
  </tr>
  <tr>
    <td><?php echo Kohana::lang('customer_lang.lbl_password')?>:</td>
    <td><input type="text" name="txt_pass" id="txt_pass" size="50"/>
    <?php if(isset($mr['customers_id']) && $mr['customers_id']) echo Kohana::lang('customer_lang.lbl_set_new_pass')?>
    </td>
  </tr>
  <!--<tr>
    <td><?php echo Kohana::lang('customer_lang.lbl_name')?>:</td>
    <td><input name="txt_name" type="text" id="txt_name" value="<?php //echo isset($mr)?$mr['customers_name']:''?>"/></td>
  </tr>-->
  <tr>
    <td><?php echo Kohana::lang('customer_lang.lbl_first_name')?>: <font color="#FF0000">*</font></td>
    <td><input type="text" name="txt_firstname" id="txt_firstname" size="50" value="<?php echo isset($mr['customers_firstname'])?$mr['customers_firstname']:''?>"/></td>
  </tr>
  <tr>
    <td><?php echo Kohana::lang('customer_lang.lbl_last_name')?>:</td>
    <td><input type="text" name="txt_lastname" id="txt_lastname" size="50" value="<?php echo isset($mr['customers_lastname'])?$mr['customers_lastname']:''?>"/></td>
  </tr>
  <tr>
    <td><?php echo Kohana::lang('customer_lang.lbl_email')?>: <font color="#FF0000">*</font></td>
    <td><input type="text" name="txt_email" id="txt_email" value="<?php echo isset($mr['customers_email'])?$mr['customers_email']:''?>" size="50"/></td>
  </tr>
  <tr>
    <td><?php echo Kohana::lang('customer_lang.lbl_address')?>:</td>
    <td><input type="text" name="txt_address" id="txt_address" value="<?php echo isset($mr['customers_address'])?$mr['customers_address']:''?>" size="50" maxlength="50"/></td>
  </tr>
  <tr>
    <td><?php echo Kohana::lang('customer_lang.lbl_address')?> 2:</td>
    <td><input type="text" name="txt_address2" id="txt_address2" value="<?php echo isset($mr['customers_address2'])?$mr['customers_address2']:''?>" size="50" maxlength="50"/></td>
  </tr>
  <tr>
    <td><?php echo Kohana::lang('customer_lang.lbl_city')?>:</td>
    <td>
    <input type="text" name="txt_city" id="txt_city" size="50" value="<?php echo isset($mr['customers_city'])?$mr['customers_city']:''?>"/></td>
  </tr>
  <tr>
    <td><?php echo Kohana::lang('customer_lang.lbl_state')?>:</td>
    <td>
    <select name="sel_state" id="sel_state" style="width:330px">
        <option value="">---</option>
        <?php for($i=0; $i<count($list_state); $i++) { ?>
        <option value="<?php echo $list_state[$i]['state_code']?>" <?php if(isset($mr['customers_state']) && $list_state[$i]['state_code'] == $mr['customers_state']) echo 'selected="selected"'?> ><?php echo $list_state[$i]['state_name']?></option>
        <? } ?>
    </select></td>
  </tr>
  <tr>
    <td><?php echo Kohana::lang('customer_lang.lbl_zipcode')?>:</td>
    <td><input type="text" name="txt_zipcode" id="txt_zipcode" size="50" value="<?php echo isset($mr['customers_zipcode'])?$mr['customers_zipcode']:''?>"/></td>
  </tr>
  <tr>
    <td><?php echo Kohana::lang('customer_lang.lbl_phone')?>:</td>
    <td><input type="text" name="txt_phone" id="txt_phone" size="50" value="<?php echo isset($mr['customers_phone'])?$mr['customers_phone']:''?>"/></td>
  </tr>
  <tr>
    <td><?php echo Kohana::lang('customer_lang.lbl_fax')?>:</td>
    <td><input type="text" name="txt_fax" id="txt_fax" size="50" value="<?php echo isset($mr['customers_fax'])?$mr['customers_fax']:''?>"/></td>
  </tr>
  <tr>
    <td valign="top"><?php echo Kohana::lang('customer_lang.lbl_note')?>:</td>
    <td>
    <textarea id="txt_note" name="txt_note" cols="63" rows="5"><?php echo isset($mr['customers_note'])?$mr['customers_note']:''?></textarea>
    </td>
  </tr>
  <tr>
    <td><?php echo Kohana::lang('customer_lang.lbl_register_date')?>:</td>
    <td>
    <input type="text" id="txt_date" name="txt_date" size="10" value="<?php echo isset($mr['customers_registered_date'])?$mr['customers_registered_date']:''?>"/>
    <a onclick="if(self.gfPop)gfPop.fPopCalendar(document.frm.txt_date);return false;"><img align="absmiddle" src="<?php echo $this->site['base_url']?>themes/plugins/calendar/calbtn.gif"></a>
    </td>
  </tr>
  <tr>
    <td><?php echo Kohana::lang('customer_lang.lbl_type')?>:</td>
    <td><select name="sel_type" id="sel_type">
      <option value="0" ><?php echo Kohana::lang('customer_lang.lbl_general')?></option>
      <option value="1" <?php if(isset($mr['customers_type']) && $mr['customers_type'] == 1) echo 'selected' ?> ><?php echo Kohana::lang('customer_lang.lbl_wholesaler')?></option>
    </select>
    </td>
  </tr>  
  <tr>
    <td><?php echo Kohana::lang('admin_lang.lbl_status')?>:</td>
    <td><select name="sel_status" id="sel_status">
      <option value="0" ><?php echo Kohana::lang('admin_lang.lbl_inactive')?></option>
      <option value="1" <?php if(isset($mr['customers_status']) && $mr['customers_status'] == 1) echo 'selected' ?> ><?php echo Kohana::lang('admin_lang.lbl_active')?></option>
    </select></td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td><input name="hd_username" type="hidden" id="hd_username" value="<?php echo isset($mr)?$mr['customers_username']:''?>" />
      <input name="hd_id" type="hidden" id="hd_id" value="<?php echo isset($mr['customers_id'])?$mr['customers_id']:''?>" /></td>
  </tr>
</table>
<iframe width=174 height=189 name="gToday:normal:agenda.js" id="gToday:normal:agenda.js" src="<?php echo $this->site['base_url']?>themes/plugins/calendar/ipopeng.htm" scrolling="no" framebproposal="0" style="visibility:visible; z-index:999; position:absolute; top:-500px; left:-500px;"></iframe>